<html>
<head>
<title>IsCombedTIVTC</title>
<link rel="stylesheet" type="text/css" href="../../avisynth.css">
<!--
Automatically generated, don't change:
$Id: tivtc_iscombedtivtc.htm,v 1.1 2005/07/10 16:11:01 wilbertd Exp $ 
-->
</head>
<body>
<h1>IsCombedTIVTC</h1>
<h2>Abstract</h2>
<b>author:</b>    tritical
<br><b>version:</b>         04/20/2005<br>
<b>download:</b>   <a href="http://bengal.missouri.edu/~kes25c/">http://bengal.missouri.edu/~kes25c/</a>
<br><b>category:</b>    Deinterlacing &amp; Pulldown Removal
<br><b>requirements:</b>&nbsp;
<ul>
  <li>YV12 &amp; YUY2 Colorspace</li>
</ul>

<p><b>license:</b> GPL</p>

<hr size=2 width="100%" align=center>

<!-- #EndTemplate -->
<h2>Description
</h2>
<p>IsCombedTIVTC is a utility function that can be used with AviSynth's conditionalfilter.
It uses TFM's inbuilt combed frame detection to test whether or not a frame is combed and returns true if it is and false if it isn't.</p>
<h3>Syntax</h3>
<p><code>IsCombedTIVTC</code> (clip, int <var>&quot;cthresh&quot;</var>, int <var>&quot;MI&quot;</var>, bool
<var>&quot;chroma&quot;</var>, int <var>&quot;blockx&quot;</var>, int <var>&quot;blocky&quot;</var>)</p>
<h3>Example</h3>
<pre>conditionalfilter(last,source1,source2,&quot;IsCombedTIVTC&quot;,&quot;=&quot;,&quot;true&quot;)</pre>
<h2>Parameters</h2>
<p>     The parameters are exactly the same as the corresponding parameters in TFM so I have     just copied their descriptions... note that the default values do differ slightly.</p>
<p><var>cthresh</var> -</p>
<p>This is the area combing threshold used for combed frame detection.  It is like         dthresh or dthreshold in telecide() and fielddeinterlace().  This essentially         controls how "strong" or "visible" combing must be to be detected.  Larger values
mean combing must be more visible and smaller values mean combing can be less visible or strong and still be detected.  Valid settings are from -1 (every pixel
will be detected as combed) to 255 (no pixel will be detected as combed).  This is basically a pixel difference value.  A good range is between 8 to 12.</p>
<p>Default:  10  (int)</p>
<p><var>MI</var> -</p>
<p>The # of combed pixels inside any of the blocky by blockx size blocks on the frame         for the frame to be detected as combed. While cthresh controls how "visible" the         combing must be, this setting controls "how much" combing there must be in any localized         area (a window defined by the blockx and blocky settings) on the frame.  Min setting = 0,         max setting = blocky x blockx (at which point no frames will ever be detected as combed).</p>
<p>Default:  85  (int)</p>
<p><var>chroma</var> -</p>
<p>Sets whether or not chroma is considered in the combed frame decision.  Only disable this if your source has chroma problems (rainbowing, etc...) that are
causing problems for the combed frame detection with chroma enabled.</p>
<p>true = chroma is included<br>
            false = chroma is not included</p>
<p>Default:  true  (bool)</p>
<p><var>blockx</var> -</p>
<p>Sets the x-axis size of the window used during combed frame detection.  This has
to do with the size of the area in which MI number of pixels are required to be detected as combed for a frame to be declared combed.  See the MI parameter
description for more info.  Possible values are any number that is a power of 2 starting at 4 and going to 2048 (i.e. 4, 8, 16, 32, ... 2048).</p>
<p>Default:  16  (int)</p>
<p><var>blocky</var> -</p>
<p>Sets the y-axis size of the window used during combed frame detection.  This has
to do with the size of the area in which MI number of pixels are required to be detected as combed for a frame to be declared combed.  See the MI parameter
description for more info.  Possible values are any number that is a power of 2 starting at 4 and going to 2048 (i.e. 4, 8, 16, 32, ... 2048).</p>
<p>Default:  16  (int)</p>
<p><kbd>$Date: 2005/07/10 16:11:01 $</kbd>
</p>
</body>
</html>
